//
//  VedioPlayerManager.m
//  yjw-winner
//
//  Created by 王春辉 on 2018/9/14.
//  Copyright © 2018年 Shanghai decade financial information service co., LTD. All rights reserved.
//

#import "VedioPlayerManager.h"
#import <AVFoundation/AVFoundation.h>

static VedioPlayerManager *_manager = nil;
@interface VedioPlayerManager () {
    View_VedioPlayer *_playerView;
}
@property (nonatomic, strong) AVPlayerItem *playerItem;
@property (nonatomic, strong) AVPlayer *player;
@property (nonatomic, strong) id timeObserver;
@property (nonatomic, strong) id itemEndObserver;
@property (nonatomic, strong) id applicationObserver;
@property (nonatomic, assign) float lastPlaybackRate;
@property (nonatomic, copy) NSString *url;
@end
@implementation VedioPlayerManager

+ (VedioPlayerManager *)manager {
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        _manager = [[VedioPlayerManager alloc] init];
    });
    return _manager;
}
- (instancetype)init {
    if (self = [super init]) {
        _playerView = [View_VedioPlayer vedioPlayerView];
    }
    return self;
}
- (View_VedioPlayer *)playerView {
    return _playerView;
}





@end
